package com.example.yunJie.digitalSentry.service.impl;


import com.example.yunJie.digitalSentry.entity.DateEntity;
import com.example.yunJie.digitalSentry.mapper.one.DateMapper;
import com.example.yunJie.digitalSentry.service.DateService;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

import java.io.Serializable;
import java.util.List;

@Service
@RequiredArgsConstructor
public class DateServiceImpl implements DateService {

    private final DateMapper dateMapper;

    @Override
    public int insert(DateEntity dateEntity) {
        return dateMapper.insert(dateEntity);
    }

    @Override
    public int update(DateEntity dateEntity) {
        return dateMapper.update(dateEntity);
    }

    @Override
    public int deleteById(Serializable id) {
        return dateMapper.deleteById(id);
    }

    @Override
    public int deleteIdList(List<Integer> idList) {
        return dateMapper.deleteIdList(idList);
    }

    @Override
    public DateEntity findId(String id) {
        return dateMapper.findId(id);
    }

    @Override
    public DateEntity findByDate(String date) {
        return dateMapper.findByDate(date);
    }

    @Override
    public List<DateEntity> findAll(DateEntity dateEntity) {
        return dateMapper.findAll(dateEntity);
    }
}
